import { get, post, put } from "./http.js";
//注册接口
export const apiRegister = (p) => post("/api/registerApp", p);
// 获取验证码
export const apiGetVerificationCode = (g) => get(`/api/verificationCode/${g}`);
// 验证邮箱接口
export const apiForgotEmail = (p) => post("/api/forgotEmail", p);
// app端登录接口
export const apiLoginApp = (p) => post("/api/loginApp", p);
// 重置密码接口
export const apiChangePassword = (p) => post("/api/changePassword", p);
// 个人中心-获取隐私说明接口
export const apiGetPrivacyStatement = () => get("/person/getPrivacyStatement");
// 个人中心-联系我们接口
export const apiGetContactUs = () => get("/person/contactUs");
// 个人中心-退出登录接口
export const apiGetLogout = () => get("/person/logout");
// 个人中心-更改密码-邮箱发送验证码接口
export const apiGetPersonVerificationCode = (g) => get(`/person/verificationCode/${g}`);
// 个人中心-重置密码接口
export const apiPersonChangePassword = (p) => post("person/changePassword", p);
// 个人中心-更改电子邮件接口
export const apiChangeUsername = (p) => post("person/changeUsername", p);
// 个人信息-查询用户信息接口
export const apiGetInfo = () => get("system/user/getDetail");
// 个人中心-个人信息修改接口
export const apiUpdateUser = (p) => put("person/updateUser", p);
// 文件上传
export const apiUpload = (p) => post("/common/upload", p);
// 轮播接口 
export const apiRotationList = () => get("/rotation/list");
// vip列表查询
export const apiVipList = (p) => get("/advertisement/getVipList", p);
// vip广告详情接口
export const apiVipDetail = (p) => get(`/advertisement/vipDetail/${p}`);
// 首页类型分类/分类字典数据获取
export const apiAdvertisingClassification = () => get("/system/dict/data/type/advertisingClassification");
// 职业类型查询
export const apiOccupation = () => get("/system/dict/data/type/occupation");
// 种族类型查询
export const apiRace = () => get("/system/dict/data/type/race");
// 语言类型查询
export const apiLanguage = () => get("/system/dict/data/type/language");
// available类型查询
export const apiAvailable = () => get("/system/dict/data/type/available");
// 推荐广告列表
export const apiGetRecommendList = (p) => get("/advertisement/getRecommendList", p);
// 全部广告列表
export const apiGetAllList = (p) => get("/advertisement/getAllList", p);
// 没参数全部列表
export const apiAllList = (p) => get("/advertisement/list", p);
// 主页广告详情
export const apiGetAllList_detail = (p) => get(`/advertisement/${p}`);
// 金额数据及系统配置获取接口
export const apiConfigurationList = () => get("/configuration/list");
// 消息提示获取接口
export const apiGetRemark = () => get("/advertisement/getRemark/1");
// 获取当前城市名称与广告总数
export const apiGetAdvertisementCount = () => get("/advertisement/getAdvertisementCount");
// 我的广告-广告弹窗数据
export const apiUpdateRemark = (p) => put("/advertisement/updateRemark", p);
// 广告草稿列表获取接口
export const apiGetAdvertisingDraft = () => get("/advertisement/getAdvertisingDraft");
// 地址数据获取
export const apiGetDeptList = () => get("/system/dept/list");
// 地址数据获取===>带参数
export const apiGetDeptList_p = (p) => get("/system/dept/list", p);
// 地址树形数据获取
export const apiGetUserDeptTree = () => get("/system/user/deptTree");

//发布广告接口
export const apiPOSTadvertisement = (p) => post("/advertisement", p);
//发布广告接口
export const apiPOSTadvertisement_put = (p) => put("/advertisement", p);

// 广告发布列表获取接口
export const apiGetAdvertisingReleaseList = () => get("/advertisement/getAdvertisingReleaseList");
// newmessage 的问号提示
export const apiGetMessagePrompt = () => get("/system/dict/data/type/message_prompt");
// upgrade的问号提示
export const apiGetUpgradePrompt = () => get("/system/dict/data/type/upgrade_prompt ");
// gaincustomer的问号提示
export const apiGetCustomerPrompt = () => get("/system/dict/data/type/customer_prompt ");
// upgrde的下拉框分类
export const apiGetUpgradeSelect = () => get("/system/dict/data/type/upgrade_select");
// 广告草稿发布接口
export const apiAdvertisingRelease = (p) => post("/advertisement/getAdvertisingRelease", p);
// 升级客户数下拉框分类key
export const apiGainCustomers = () => get("/system/dict/data/type/gaincustomers");
// 修改广告草稿接口
export const apiUpdateDraft = (p) => put("/advertisement/updateAdvertisingDraft", p);
// 金额类型查询
export const apiBalance = () => get("/system/dict/data/type/balance");
// 充值接口
export const apiRecharge = (p) => put("/advertisement/recharge", p);
// 获取当前广告金额
export const apiGetAdvertisementMoney = () => get("/advertisement/getAdvertisementMoney");
// 我的广告 - 查询草稿详情接口
export const apiGetAdDetail = (p) => get(`/advertisement/${p}`);
// 我的广告 - 签到接口
export const apiSignDays = (p) => put(`/system/user/signDays`,p)
// 我的广告 - 删除草稿信息接口
export const apiAdvertisingDelete = (p)=> post(`/advertisement/${p}`)